import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import jsx from '@vitejs/plugin-vue-jsx'
import path from 'path'

// https://vitejs.dev/config/
export default defineConfig({
  plugins: [vue(), jsx()],
  resolve: {
    alias: [
      {
        find: '@',
        replacement: path.resolve(__dirname, 'src'),
      },
      {
        find: 'vv',
        replacement: path.resolve(__dirname, 'src/views'),
      },
      {
        find: 'api',
        replacement: path.resolve(__dirname, 'src/api'),
      },
      {
        find: 'cc',
        replacement: path.resolve(__dirname, 'src/components'),
      },
    ],
  },
})
